import {getGoodDetail} from "http"
export default {
    state:{
        goodDetail:{}//获取商品选项

    },
    mutations:{
        getGoodDetail(state,goodDetail){
            state.goodDetail = goodDetail
        },
    },
    actions:{
        async getGoodDetail({commit},skuid){
            const {code,data} = await getGoodDetail(skuid);
            console.log(data);
            if(code === 200){
                commit("getGoodDetail",data)
            }
        },
    }
}